﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace Transportr
{
    public class TimetableItemViewModel : BaseItemViewModel
    {
        private int mHour;
        private string mRecord;

        public int Hour
        {
            get { return mHour; }
            set
            {
                if (value != mHour)
                {
                    mHour = value;
                    NotifyPropertyChanged("Hour");
                }
            }
        }

        public string Record
        {
            get { return mRecord; }
            set
            {
                if (value != mRecord)
                {
                    mRecord = value;
                    NotifyPropertyChanged("Record");
                }
            }
        }

        public Color BackgroundColor
        {
            get
            {
                if (mHour % 2 == 0)
                    return Colors.DarkGray;
                else
                    return Colors.LightGray;
            }
        }
    }
}
